﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace OgonPhonesXML.Cisco.Serializer
{
    [System.CodeDom.Compiler.GeneratedCodeAttribute("xsd", "2.0.50727.3038")]
    [System.SerializableAttribute()]
    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.ComponentModel.DesignerCategoryAttribute("code")]
    [System.Xml.Serialization.XmlRootAttribute("CiscoIPPhoneGraphicMenu", Namespace = "", IsNullable = false)]
    public partial class CiscoIPPhoneGraphicMenuType
    {
        private string titleField;

        private string promptField;

        private short locationXField;

        private bool locationXFieldSpecified;

        private short locationYField;

        private bool locationYFieldSpecified;

        private ushort widthField;

        private ushort heightField;

        private ushort depthField;

        private byte[] dataField;

        private CiscoIPPhoneMenuItemType[] menuItemField;
        private List<CiscoIPPhoneMenuItemType> listMenuItem = new List<CiscoIPPhoneMenuItemType>();

        private CiscoIPPhoneSoftKeyType[] softKeyItemField;
        private List<CiscoIPPhoneSoftKeyType> listSoftKey = new List<CiscoIPPhoneSoftKeyType>();

        public void addMenuItem(string name, string url)
        {
            CiscoIPPhoneMenuItemType psvMenuItem = new CiscoIPPhoneMenuItemType();
            psvMenuItem.Name = name;
            psvMenuItem.URL = url;
            listMenuItem.Add(psvMenuItem);
        }
        public void addSoftKey(string name, string url, ushort position)
        {
            CiscoIPPhoneSoftKeyType psvSoftKey = new CiscoIPPhoneSoftKeyType();
            psvSoftKey.Name = name;
            psvSoftKey.URL = url;
            psvSoftKey.Postion = position;
            listSoftKey.Add(psvSoftKey);
        }
        /// <comentarios/>
        [System.Xml.Serialization.XmlElementAttribute(Form = System.Xml.Schema.XmlSchemaForm.Unqualified)]
        public string Title
        {
            get
            {
                return this.titleField;
            }
            set
            {
                this.titleField = value;
            }
        }

        /// <comentarios/>
        [System.Xml.Serialization.XmlElementAttribute(Form = System.Xml.Schema.XmlSchemaForm.Unqualified)]
        public string Prompt
        {
            get
            {
                return this.promptField;
            }
            set
            {
                this.promptField = value;
            }
        }

        /// <comentarios/>
        [System.Xml.Serialization.XmlElementAttribute(Form = System.Xml.Schema.XmlSchemaForm.Unqualified)]
        public short LocationX
        {
            get
            {
                return this.locationXField;
            }
            set
            {
                this.locationXField = value;
            }
        }

        /// <comentarios/>
        [System.Xml.Serialization.XmlIgnoreAttribute()]
        public bool LocationXSpecified
        {
            get
            {
                return this.locationXFieldSpecified;
            }
            set
            {
                this.locationXFieldSpecified = value;
            }
        }

        /// <comentarios/>
        [System.Xml.Serialization.XmlElementAttribute(Form = System.Xml.Schema.XmlSchemaForm.Unqualified)]
        public short LocationY
        {
            get
            {
                return this.locationYField;
            }
            set
            {
                this.locationYField = value;
            }
        }

        /// <comentarios/>
        [System.Xml.Serialization.XmlIgnoreAttribute()]
        public bool LocationYSpecified
        {
            get
            {
                return this.locationYFieldSpecified;
            }
            set
            {
                this.locationYFieldSpecified = value;
            }
        }

        /// <comentarios/>
        [System.Xml.Serialization.XmlElementAttribute(Form = System.Xml.Schema.XmlSchemaForm.Unqualified)]
        public ushort Width
        {
            get
            {
                return this.widthField;
            }
            set
            {
                this.widthField = value;
            }
        }

        /// <comentarios/>
        [System.Xml.Serialization.XmlElementAttribute(Form = System.Xml.Schema.XmlSchemaForm.Unqualified)]
        public ushort Height
        {
            get
            {
                return this.heightField;
            }
            set
            {
                this.heightField = value;
            }
        }

        /// <comentarios/>
        [System.Xml.Serialization.XmlElementAttribute(Form = System.Xml.Schema.XmlSchemaForm.Unqualified)]
        public ushort Depth
        {
            get
            {
                return this.depthField;
            }
            set
            {
                this.depthField = value;
            }
        }

        /// <comentarios/>
        [System.Xml.Serialization.XmlElementAttribute(Form = System.Xml.Schema.XmlSchemaForm.Unqualified, DataType = "hexBinary")]
        public byte[] Data
        {
            get
            {
                return this.dataField;
            }
            set
            {
                this.dataField = value;
            }
        }

        /// <comentarios/>
        [System.Xml.Serialization.XmlElementAttribute("MenuItem")]
        public CiscoIPPhoneMenuItemType[] MenuItem
        {
            get
            {
                this.menuItemField = listMenuItem.ToArray();
                return this.menuItemField;
            }
            set
            {
                this.menuItemField = value;
            }
        }

        /// <comentarios/>
        [System.Xml.Serialization.XmlElementAttribute("SoftKeyItem")]
        public CiscoIPPhoneSoftKeyType[] SoftKeyItem
        {
            get
            {
                this.softKeyItemField = listSoftKey.ToArray();
                return this.softKeyItemField;
            }
            set
            {
                this.softKeyItemField = value;
            }
        }
    }
}
